import React, { Component } from 'react'

class Third extends Component {
    render() {
        return (
            <div>
              { this.props.theme }
            </div>
        )
    }
}

class Second extends Component {
    render() {
        return (
            <div>
              <Third theme = { this.props.theme }></Third>
            </div>
        )
    }
}

export default class App extends Component {
    state = {
        theme: 'dark'
    }
    render() {
        return (
            <div>
                <Second theme = { this.state.theme }></Second>
            </div>
        )
    }
}